package com.atguigu.eduservice.service.client;

import com.atguigu.commonutils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(value = "service-vod",fallback =VodFileDegradeFeignClient.class)  // 要调用的服务名
public interface VodClient {

    // 根据视频 id，进行删除阿里视频点播中的视频
    @DeleteMapping("/dev-api/eduvod/video/removeAlyVideo/{VodId}")
    public R delete(@PathVariable("VodId")String id);

    // 根据传递过来的多个 id，进行删除
    @DeleteMapping("/dev-api/eduvod/video/deleteBatch")
    public R deleteBatch(@RequestParam("videoIdList") List<String> videoIdList);
}
